home *** CD-ROM | disk | FTP | other *** search
- Subject: Enable/Disable all menu items
- Sent: 6/8/96 12:17 PM
- Received: 6/10/96 8:59 AM
- From: Nolan Larsen, nlarsen@dharbor.com
- Reply-To: ODF Interest, ODF-Interest@CILabs.ORG
- To: OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
-
- I came across a couple of bugs in the file FWPullDM.cpp of ODF d11 and sent
- the following message. After making the switch to R1 I have found that the
- same bug exists. Will this be fixed in a future version?
-
- The FW_CPullDownMenu::EnableAll method uses the following code:
-
- (*fPlatformMenu)->enableFlags &= 0xFFFFFFFF;
-
- ANDing everything with 1 does nothing to enableFlags. In fact, the compiler
- optimizes the code out so nothing is generated to enable the menus. The
- following will produce the desired effect:
-
- (*fPlatformMenu)->enableFlags = 0xFFFFFFFF;
-
-
- The FW_CPullDownMenu::DisableAll has a slightly different problem. It uses
- the following line of code to disable all of the menu items:
- (*fPlatformMenu)->enableFlags &= 0x00000001;
- This code does disable all of the items but does not disable the menu
- itself. According to the HI guidelines, if all menu items are disabled the
- menu title should also be disabled. The following is more in keeping with
- the guidelines:
-
- (*fPlatformMenu)->enableFlags = 0x00000000;
-
- Thanks,
- Nolan
-
- =========================================================================
- Nolan Larsen Digital Harbor
- nlarsen@dharbor.com "Pier-to-Pier Computing"
- =========================================================================
-
-